import request from '@/utils/request'


export function list(params: any) {
  return request({
    method: 'get',
    url: '/admin',
    params
  })
}
export function add(data: any) {
  return request({
    method: 'post',
    url: '/admin',
    data
  })
}

export function userdel(data: any) {
  return request({
    method: 'delete',
    url: '/admin',
    data
  })
}

export function detail(id: number) {
  return request({
    method: 'get',
    url: '/admin/' + id
  })
}

export function updated(data: any) {
  return request({
    method: 'put',
    url: '/admin',
    data
  })
}